package com.cskaoyan.bean.wxvo;

import lombok.Data;

@Data
public class WxCouponReceiveVo {
    //优惠劵状态信息

    /**
     * 0:领取成功
     * 740:优惠劵已领取过
     * 742:优惠劵兑换码不正确
     * 745:优惠劵已过期
     * 747:优惠劵参数错误
     * 500:领取优惠劵失败
     */

    Integer errno;

    String errmsg;

    public static WxCouponReceiveVo ok() {
        WxCouponReceiveVo wxCouponReceiveVo = new WxCouponReceiveVo ();
        wxCouponReceiveVo.setErrno (0);
        wxCouponReceiveVo.setErrmsg ("优惠劵领取成功!");
        return wxCouponReceiveVo;
    }

    public static WxCouponReceiveVo have() {
        WxCouponReceiveVo wxCouponReceiveVo = new WxCouponReceiveVo ();
        wxCouponReceiveVo.setErrno (740);
        wxCouponReceiveVo.setErrmsg ("该劵已领取过");
        return wxCouponReceiveVo;
    }

    public static WxCouponReceiveVo fail() {
        WxCouponReceiveVo wxCouponReceiveVo = new WxCouponReceiveVo ();
        wxCouponReceiveVo.setErrno (500);
        wxCouponReceiveVo.setErrmsg ("优惠劵领取失败");
        return wxCouponReceiveVo;
    }

    public static WxCouponReceiveVo codeFalse() {
        WxCouponReceiveVo wxCouponReceiveVo = new WxCouponReceiveVo ();
        wxCouponReceiveVo.setErrno (742);
        wxCouponReceiveVo.setErrmsg ("优惠劵码不正确");
        return wxCouponReceiveVo;
    }

    public static WxCouponReceiveVo overDate() {
        WxCouponReceiveVo wxCouponReceiveVo = new WxCouponReceiveVo ();
        wxCouponReceiveVo.setErrno (745);
        wxCouponReceiveVo.setErrmsg ("优惠劵已过期");
        return wxCouponReceiveVo;
    }
    public static WxCouponReceiveVo couponDataFalse() {
        WxCouponReceiveVo wxCouponReceiveVo = new WxCouponReceiveVo ();
        wxCouponReceiveVo.setErrno (747);
        wxCouponReceiveVo.setErrmsg ("优惠劵参数错误");
        return wxCouponReceiveVo;
    }
}
